In a motor system 100, a flexible motor driver IC 104 includes synchronous rectification for low power dissipation and can be used to drive not only a DC motor 102 but also a stepper motor 106 shown in FIG. 1. Motor driver IC 104 is externally controlled by a μC 108, which is coupled to internal pulse-width modulation (“PWM”) and control logic block 110. The sense resistor RS1 between the SENSE1 node and ground is used for driving stepper motor 106. When driving the DC motor 102, RS1 is shorted to ground. Resistor RS2 ideally has the same value as RS1. Blanking time of “bta” or “btb” generated with “Lain” or “LBin” is applied to pre-driver and OCD circuits 112 and 114 used for pre-driving H-bridges 116 and 118, and for OCD. When OCD happens, the outputs of H-bridges 116 and 118 are tri-stated until the next PWM pulse arrives.
When a PWM off-cycle is triggered, either by a bridge disable command or an off-time cycle, synchronous rectification is activated. The motor driver IC 104 turns on the appropriate power DMOS device with low Rdson during the current decay to short the body diodes effectively. This feature can eliminate the need for external Schottky diodes for most applications, saving cost and external component count, while minimizing power dissipation significantly.
Referring now to FIG. 2, a portion of a motor driver system 200 is shown including an H-bridge 202, a motor 204, and a sense resistor RS. Normally, in the driver system 200 shown in FIG. 2 there are three kinds of current decay modes, which are fast decay, slow decay and mixed decay. The normal “on” current flow is I1, the fast decay path is I2, and the slow decay path is I3. The mixed decay path is a combination of I2 and I3 during the “off” time.
In the case where a longer time is required to turn a DC motor on or a fast decay with synchronous rectification occurs, a large current in the coil of motor 204 is produced. For a stepper motor, there are some accidents that can cause a large current occurrence in motor 204. For example, if sense resistor RS becomes small or shorted to ground suddenly, or if there is a longer decay time, either will cause a large current to flow. The larger than normal current can damage the motor 204 and coil. So it is mandatory to provide over current protection in a motor driver IC.
The traditional motor driver circuit 300 with over current detection protection for a DC motor 302 is shown in FIG. 3, which includes a sense portion 304 and a comparison portion 306. The sense portion 304 includes sensing transistors Msa and Msb. The comparison portion 306 includes sense resistors Rsa and Rsb, reference resistors Rrefa and Rrefb, reference current sources Irefa and Irefb, flip-flops 308 and 310, and comparators 312 and 314. Circuit 300 also includes an H-bridge 316, pre-driver circuits 318 and 320, and logic gates 322 and 324.
In the traditional structure shown in FIG. 3, side A and side B of H-bridge 316 have separate sense 304 and comparison 306 portions. The separated OCD structure shown in FIG. 3 causes undesirable different detection thresholds for each side due to process variations in the integrated circuit.
Referring now to FIG. 4, a traditional OCD circuit for “side A” of the H-bridge is shown. The sense part includes a current mirror of transistor LA from the H-bridge and sensing transistor Msa with a cell ratio of “n”, and a current sense resistor of Rsa. Also shown in FIG. 4 is comparator 412, reference current Irefa, and reference resistor Rrefa.
Referring now to FIG. 5, an additional traditional OCD circuit for “side A” of the H-bridge is shown. The sense part includes a current mirror of transistor LA from the H-bridge and sensing transistor Msa with a cell ratio of “n”, and a current sense resistor of Rsa. Also shown in FIG. 5 is comparator 512, reference current Irefa, reference resistor Rrefa, as well as external sense resistor Rtex coupled to the SENSE node.
When transistors LA and Msa work in the triode mode, their drain currents can be expressed as follows:
                              I          LA                =                              K            LA                    ×                      [                                                            (                                                            V                      gsLA                                        -                                          V                      thLA                                                        )                                ×                                  V                  dsLA                                            -                                                V                  dsLA                  2                                2                                      ]                                              (        1        )                                          I          Msa                =                              K            Msa                    ×                      [                                                                                                      (                                                                        V                          gsLA                                                -                                                  V                          sa                                                -                                                  V                          thMsa                                                                    )                                        ×                                                                                                                                          (                                                                        V                          dsLA                                                -                                                  V                          sa                                                                    )                                        -                                                                                            (                                                                                    V                              dsLA                                                        -                                                          V                              sa                                                                                )                                                2                                            2                                                                                            ]                                              (        2        )            where VdsMsa=VdsLA−Vsa VgsMsa=VgsLA−Vsa VthLA=VthMsa=Vth Setting the mirroring factor n1 is expressed by:
                              n          1                =                              I            LA                                I            Msa                                              (        3        )            Substituting (1) and (2) into (3), n1 results in:
                              n          1                =                                            K              LA                        ×                          [                                                                    (                                                                  V                        gsLA                                            -                                              V                        th                                                              )                                    ×                                      V                    dsLA                                                  -                                                      V                    dsLA                    2                                    2                                            ]                                                          K              Msa                        ×                          [                                                                                                                  (                                                                              V                            gsLA                                                    -                                                      V                            sa                                                    -                                                      V                            th                                                                          )                                            ×                                                                                                                                                          (                                                                              V                            dsLA                                                    -                                                      V                            sa                                                                          )                                            -                                                                                                    (                                                                                          V                                dsLA                                                            -                                                              V                                sa                                                                                      )                                                    2                                                2                                                                                                        ]                                                          (        4        )            The cell ratio of n is expressed by:
                    n        =                              K            LA                                K            Msa                                              (        5        )            Thus (4) can be simplified as follows:
                    n        =                  n                      1            -                                                            V                  sa                                ×                                  (                                                            V                      gsLA                                        -                                          V                      th                                        -                                                                  V                        sa                                            2                                                        )                                                                              V                  dsLA                                ×                                  (                                                            V                      gsLA                                        -                                          V                      th                                        -                                                                  V                        dsLA                                            2                                                        )                                                                                        (        6        )            Assuming Vsa and VdsLA are smaller than VgsLA and Vth, n1 can be simplified by:
                              n          1                =                  n                      1            -                                          V                sa                                            V                dsLA                                                                        (        7        )            So Vsa is traded off between the mirrored current of IMsa and sense resistance of Rsa.AndVsa=Rsa×IMsa  (8)VdsLA=RdsonLA×ILA  (9)Substituting (8) and (9) into (7), n1 can be expressed by:
                              n          1                =                  n          +                                    R              sa                                      R              dsonLA                                                          (        10        )            As is known, RdsonLA is a function of temperature, and so n1 also changes with temperature.Vsa can also be expressed by:
                              V          sa                =                                                            I                LA                                            n                1                                      ×                          R              sa                                =                                                    I                LA                            n                        ×                          (                              1                -                                                      V                    sa                                                        V                    dsLA                                                              )                        ×                          R              sa                                                          (        11        )            thus:
                              V          sa                =                              I            LA                                              n                              R                sa                                      +                          1                              R                dsonLA                                                                        (        12        )            and Vrefa is obtained by:Vrefa=Irefa×Rrefa  (13)From (11) and (12), it can be seen that VMsa and Vrefa have no similar temperature feature.Assuming VMsa is equal to Vrefa, the threshed OCD current of Ithocd is obtained by:
                              I          thocd                =                                                            R                refa                                            R                sa                                      ×                          n              1                        ×                          I              refa                                =                                    (                                                                                          R                      refa                                                              R                      sa                                                        ×                  n                                +                                                      R                    refa                                                        R                    dsLA                                                              )                        ×                          I              refa                                                          (        14        )            If Rrefa and Rsa are the same type of resistor, Ithocd depends on n, and the ratio of Rrefa and RdsLA, but Rrefa and RdsLA are different type resistors. Therefore Ithocd also changes with temperature and process variation.
Normally, from the SENSE pin to ground there is an external trace resistance of Rtex as shown in FIG. 5. When ILA flows through Rtex, a voltage drop of VSEN is generated as shown in FIG. 6.
Comparing circuit 600 in FIG. 6 to circuit 400 of FIG. 4, if LA1 and Rtex are compared to Msa and Rsa respectively, similar results are obtained. Setting the mirroring factor of m1 between LA and LA1 is expressed by:
                              m          1                =                                            I              LA                                      I                              LA                ⁢                                                                  ⁢                1                                              =                      m                          1              -                                                V                  SEN                                                  V                  dsLA                                                                                        (        15        )            where m is the cell ratio of LA and LA1.From (15), it is known that when VSEN increases, m1 increases. In other words, the drain current flowing through LA decreases with respect to size, which means m is equal to one.Thus, VSEN is equal to:VSEN=Rtex×ILA1  (16)As a result, when Rtex increases, VSEN increases, m1 decreases, n1 decreases according to (3), and consequently Ithocd decreases according to (14).
It is important to note that Rtex contains a sense resistor of Rs for driving a stepper motor, and therefore Ithocd is affected by Rtex significantly. In other words, a motor driver IC has a different Ithocd for driving a DC motor and a stepper motor.
In summary, the traditional OCD circuits and method described above has certain drawbacks. Firstly, The separated OCD structure could cause a different Ithocd for each side in the H-bridge. Secondly, the sense voltage of VMsa and Vref have similar variation with temperature and process variations. Thirdly, Ithocd is sensitive to temperature and process variations as well as SENSE pin voltage. Fourthly, there is a different Ithocd for driving stepper and DC motors due to the different external sense resistor RS.
What is desired, therefore is an OCD circuit for a motor driver integrated circuit that is able to overcome each of these four drawbacks associated with the conventional prior art OCD motor driver circuits.